package com.ardf.mapper;

import com.ardf.entity.Signin;
import com.ardf.entity.dto.DownloadSignInDto;
import com.ardf.entity.dto.SignInSearchAllDto;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author ShiYunHao
 * @since 2025-01-06
 */
public interface SigninMapper extends BaseMapper<Signin> {

    /**
     *分页
     */
    Page<SignInSearchAllDto> searchAll(Page<SignInSearchAllDto> page,
                                       @Param("competitionId") Long competitionId,
                                       @Param("searchAll") String searchAll);

    /**
     *根据项目id搜索
     */
    Page<SignInSearchAllDto> searchAllByProjectId(Page<SignInSearchAllDto> page,@Param("projectId") Long projectId);

    List<DownloadSignInDto> getAll(@Param("competitionId") Long competitionId);
}
